/**
 * author tancheng
 * createDate 2015-10-10
 * 依赖bootbox.js
 * 需要初始化如下变量
 * spath 静态资源前缀路径
 * jpath webjars前缀路径
 * rpath rest服务前缀路径
 * base  当前系统的路径
 * */
if (typeof component == "undefined" || typeof component.img == "undefined") {
    if (typeof component == "undefined") {
        var component = {"img": {}};
    } else {
        component.img = {};
    }
    component.img.choose = function (title, idField, textField) {
        var url = base + "/personal/view/toUploadImg?idField=" + idField + "&textField=" + textField;
        var buttons = {
            btnOk: {
                label: '确定',
                callback: function () {
                }
            },
            btnCancel: {
                label: '取消',
                callback: function () {
                }
            }
        }
        $.messager.dialog({url: url, title: title, buttons: {}, iframe: {width: 700, height: 500,name:'img'}});
    }
}